var Controller = function(){}
	
Controller.model;
Controller.view;

Controller.setModel=function(model){
this.model = model;
}

Controller.setView=function(view){
this.view = view;
}

Controller.moveDot = function(id,x,y){
Controller.view.moveDot(id,x,y);
}


Controller.increaseConnections = function(){
	model.increaseConnections();
}
Controller.decreaseConnections = function(){
	model.decreaseConnections();
}
Controller.updateConnections = function(){
	model.updateShownConnections();
}

Controller.getMouseXY = function getMouseXY(e) {
if (Controller.IE) { // grab the x-y pos.s if browser is IE
Controller.tempX = event.clientX + document.body.scrollLeft;
Controller.tempY = event.clientY + document.body.scrollTop;
}
else {  // grab the x-y pos.s if browser is NS
Controller.tempX = e.pageX;
Controller.tempY = e.pageY;
}  
if (Controller.tempX < 0){Controller.tempX = 0;}
if (Controller.tempY < 0){Controller.tempY = 0;}

Controller.moveDot(0,Controller.tempX,Controller.tempY);

return true;
}

Controller.IE = document.all?true:false;
if (!Controller.IE) document.captureEvents(Event.MOUSEMOVE)
document.onmousedown = Controller.getMouseXY;
Controller.tempX = 0;
Controller.tempY = 0;
